#include <stdio.h>
int main(){
    int n;
    n=1;
    float x;
    scanf("%f",&x);
    x>=1.0&&x<=20.0;
    do{
            x=1+1/x;
            n=n+1;
    }while(n<=5);
    printf("%.3f",x);
    return 0;
}
